<template>
  <div class="main-content">
    <div class="login" v-show="$route.matched.length === 1">
      <div  class="section-1">
        <img src="./play (1).png">
         <svg-icon icon-class="x" class="svg-icon"></svg-icon>
        <img src="./netease.png">
      </div>
      <div class="section-2">
      <div class="card" @click="$router.push({ name: 'account' })">
        <div class="container">
          <div class="title-info">
            <div class="title">{{$t('login.loginText')}}</div>
            <div class="info">{{$t('login.accessToAll')}}</div>
          </div>
           <svg-icon icon-class="arrow-right" class="svg-icon"></svg-icon>
        </div>
      </div>
      <div class="card" @click="$router.push({ name: 'qr' })">
        <div class="container">
          <div class="title-info">
            <div class="title">{{$t('login.qrLogin')}}</div>
            <div class="info">{{$t('login.accessToAll')}}</div>
            </div>
            <svg-icon icon-class="arrow-right" class="svg-icon"></svg-icon>
          </div>
      </div>
       <div class="card" @click="$router.push({ name: 'username' })">
        <div class="container">
          <div class="title-info">
            <div class="title">{{$t('login.search')}}</div>
            <div class="info">{{$t('login.readonly')}}</div>
            </div>
            <svg-icon icon-class="arrow-right" class="svg-icon"></svg-icon>
          </div>
      </div>
      </div>
    </div>
    <router-view></router-view>
  </div>
</template>

<script>
export default {
  name: 'PlaymusicLogin',
};
</script>

<style lang="scss" scoped>
.login{
  display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: calc(100vh - 192px);
}
.section-1 {
    margin-bottom: 16px;
    display: flex;
    align-items: center;
}
.section-1 img{
    height: 64px;
    margin: 20px;
}
.section-1 .svg-icon{
    height: 24px;
    width: 24px;
    color: rgba(82,82,82,.28);
}
.section-2 {
    display: flex;
    align-items: center;
    flex-direction: column;
}
.card{
    cursor: pointer;
    margin-top: 14px;
    margin-bottom: 14px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: #eaeffd;
    border-radius: 8px;
    height: 128px;
    width: 300px;
    transition: all .3s;
    padding-left: 22px;
    box-sizing: border-box;
}
.card .container{
    display: flex;
    align-items: center;
    color: #335eea;
}
.card .title-info{
    transition: all .3s;
}
.card .title{
    font-size: 24px;
    font-weight: 600;
}
.card .info{
    margin-top: 2px;
    font-size: 14px;
    color: rgba(51,94,234,.78);
}
.card .svg-icon{
    opacity: 0;
    height: 24px;
    width: 24px;
    margin-left: 16px;
    transition: all .3s;
}
.svg-icon{
    fill: currentColor;
}
.card:hover .svg-icon{
  opacity: 1;
  margin-left: 30px;
}
</style>
